class RewardModel {
  int? errcode;
  String? errmsg;
  List<RewardItemModel>? data;
  String? message;

  RewardModel({this.errcode, this.errmsg, this.data, this.message});

  RewardModel.fromJson(Map<String, dynamic> json) {
    errcode = json['errcode'];
    errmsg = json['errmsg'];
    if (json['data'] != null) {
      data = <RewardItemModel>[];
      json['data'].forEach((v) {
        data!.add(new RewardItemModel.fromJson(v));
      });
    }
    message = json['message'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['errcode'] = this.errcode;
    data['errmsg'] = this.errmsg;
    if (this.data != null) {
      data['data'] = this.data!.map((v) => v.toJson()).toList();
    }
    data['message'] = this.message;
    return data;
  }
}

class RewardItemModel {
  int? id;
  String? typeName;
  String? status;
  String? cases;
  int? money;
  String? thing;
  String? date;

  RewardItemModel(
      {this.id,
        this.typeName,
        this.status,
        this.cases,
        this.money,
        this.thing,
        this.date});

  RewardItemModel.fromJson(Map<String, dynamic> json) {
    id = json['id'];
    typeName = json['type_name'];
    status = json['status'];
    cases = json['cases'];
    money = json['money'];
    thing = json['thing'];
    date = json['date'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['id'] = this.id;
    data['type_name'] = this.typeName;
    data['status'] = this.status;
    data['cases'] = this.cases;
    data['money'] = this.money;
    data['thing'] = this.thing;
    data['date'] = this.date;
    return data;
  }
}
